<template>
	<view class="page-container">
	  <user-center :is-login="isLogin" :login-info="loginInfo" ></user-center>
	  <my-tab-bar :active="2"></my-tab-bar>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				loginInfo:{},
				isLogin:false
			};
		},
		 onShow() {
		    let isLogin = uni.getStorageSync('isLogin') || false
		    let loginInfo
		    if(isLogin){
		      loginInfo = uni.getStorageSync('loginInfo') || {}
			  this.loginInfo = loginInfo
			  this.isLogin = true
		    }else{
				this.loginInfo = {}
				this.isLogin = false
		    }
		  },
	}
</script>

<style lang="less">
.page-container{
	padding-top: 0;
}
</style>
